list=[1,4,3,2,5]
print(list)
list.sort() # 默认升序排序  先排大写再排小写
print(list)
list.sort(reverse=True)# 降序排序
print(list)

list2 = ['xie','Zhuo','cat']
list2.sort(key=str.lower)#忽略大小写排序
print(list2)

#内置排序
list3=[1,4,3,2,5]
asc_list=sorted(list3)
print(asc_list)
desc_list=sorted(list3,reverse=True)
print(desc_list)
print(id(list3),id(asc_list),id(desc_list))